package com.bw.ivideoproject.login

import com.bw.ivideoproject.entity.BaseResp
import com.bw.ivideoproject.entity.UserEntity
import com.bw.lib_internet.BaseApi
import retrofit2.http.Field
import retrofit2.http.FormUrlEncoded
import retrofit2.http.POST
import retrofit2.http.Query

interface LoginApi : BaseApi {

    @POST("/user/login")
    @FormUrlEncoded
    suspend fun login(@Field("username") username:String,@Field("password") password:String):BaseResp<UserEntity>

    @POST("/user/register")
    @FormUrlEncoded
    suspend fun register(@Field("username") username:String,@Field("password") password:String):BaseResp<UserEntity>

}